package com.icesoft.system.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.constants.MySqlTypeConstant;
import com.icesoft.framework.core.annotation.Entity;
import com.icesoft.framework.core.entity.BaseEntity;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

@Getter
@Setter
@Accessors(chain = true)
@TableName("sys_login_record")
@Entity(module = "system", describe = "登录记录")
public class LoginRecord extends BaseEntity {

	@TableField
	@Column(value = "user_id", comment = "用户ID", length = 255, type = MySqlTypeConstant.BIGINT)
	private Long userId;

	@TableField
	@Column(value = "ip", comment = "ip", length = 255, type = MySqlTypeConstant.VARCHAR)
	private String ip;

	@TableField
	@Column(value = "city", comment = "city", length = 255, type = MySqlTypeConstant.VARCHAR)
	private String city;

	@TableField
	@Column(value = "message", comment = "登录信息", length = 255, type = MySqlTypeConstant.VARCHAR)
	private String message;

	@TableField
	@Column(value = "error", comment = "是否失败")
	private Boolean error;

}
